package com.myoffice.model;

import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * TOperatelog entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "T_OPERATELOG", schema = "OA")
public class TOperatelog implements java.io.Serializable {

	// Fields

	private String id;
	private TLoginlog TLoginlog;
	private TUserinfo TUserinfo;
	private String name;
	private String descs;
	private Date time;

	// Constructors

	/** default constructor */
	public TOperatelog() {
	}

	/** full constructor */
	public TOperatelog(String id, TLoginlog TLoginlog, TUserinfo TUserinfo,
			String name, String descs, Date time) {
		this.id = id;
		this.TLoginlog = TLoginlog;
		this.TUserinfo = TUserinfo;
		this.name = name;
		this.descs = descs;
		this.time = time;
	}

	// Property accessors
	@Id
	@Column(name = "ID", unique = true, nullable = false)
	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "OBJECTID", nullable = false)
	public TLoginlog getTLoginlog() {
		return this.TLoginlog;
	}

	public void setTLoginlog(TLoginlog TLoginlog) {
		this.TLoginlog = TLoginlog;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "USERID", nullable = false)
	public TUserinfo getTUserinfo() {
		return this.TUserinfo;
	}

	public void setTUserinfo(TUserinfo TUserinfo) {
		this.TUserinfo = TUserinfo;
	}

	@Column(name = "NAME", nullable = false)
	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Column(name = "DESCS", nullable = false)
	public String getDescs() {
		return this.descs;
	}

	public void setDescs(String descs) {
		this.descs = descs;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "TIME", nullable = false, length = 7)
	public Date getTime() {
		return this.time;
	}

	public void setTime(Date time) {
		this.time = time;
	}

}